<!DOCTYPE html >
<%@ page contentType="text/html;charset=UTF-8"%>
<%@ include file="../admin/authority.jsp" %>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<%@include file="headScriptSM.jsp"%>
<script type="text/javascript"
	src="${pageContext.request.contextPath}/assets/js/sm/cs11009script.js"></script>
</head>

<body>
<input type="hidden" id="url_address" name="url_address" value="">
<input type="hidden" id="agent_browser" name="agent_browser" value="">
	<div class="wrapper">
		<!-- BEGIN Top-Bar -->
		<%@ include file="../fragments/header.jsp"%>
		<!-- END Top-Bar -->

		<div id="detail-area" class="clearfix">
			<!-- BEGIN SIDEMENU -->
			<div class="hidden-xs hidden-sm page-sidebar" id="side-menu-bar">
				<ul class="page-sidebar-menu">					

					<!-- <div id="displaymenu"></div>  -->
					<%@ include file="../admin/menu.jsp" %>

				</ul>
			</div>
			<!-- End Side Menu -->
			<div class="col-sm-12 col-xs-12" id="right-side">
				<div id="navigator-bar">
					<i class="fa fa-home"></i> หน้าหลัก <i
						class="fa fa-angle-right ml-5 mr-5"></i>บันทึกข้อมูลประเภทคำร้อง
				</div>
				<!--End navigator-bar-->
				<!-- Start detail-area -->
				<div>
					<div id="page-header" class="clearfix">
						<div>บันทึกข้อมูลประเภทคำร้อง</div>
					</div>
					<!-- Start form-detail -->
					<div class="form-detail clearfix">
						<form role="form">
							<div class="search-box  no-radius">
								<div class="form-group clearfix search-header no-radius">
									<div class="pull-left">เพิ่มข้อมูลประเภทคำร้อง</div>
									<div class="pull-right">
										<div id="hide-button">
											<i class="fa fa-chevron-circle-up"></i>
										</div>
									</div>
								</div>
								<div id="box-body">
									<div class="form-group clearfix mt-20 ">
										<div class="col-sm-1 mt-5" style="width: 80px"></div>
										<div class="col-sm-4 mt-5">
											<div class="pull-left mt-5 ml-10 " style="width: 200px">
												<label for="inputRequestGroup">กลุ่มคำร้อง</label> <select
													class="form-control" id="inputRequestGroup">
													<option value="">-- เลือกคำร้อง --</option>
													<option value="0">เกี่ยวกับมาตร</option>
													<option value="1">ไม่เกี่ยวกับมาตร</option>
												</select>
											</div>
										</div>
										<div class="col-sm-1 mt-5">
											<div class="pull-left mt-5" style="width: 50px;">
												<label for="inputCode">รหัส</label> <input type="text"
													class="form-control" id="inputCode" name="code">
											</div>
										</div>
										<div class="col-sm-4 mt-5">
											<div class="pull-left mt-5 ml-10"
												style="width: 250px; padding-left: 25px;">
												<label for="inputDesp">รายละเอียด</label> <input type="text"
													class="form-control" id="inputDesp" name="desp">
											</div>
										</div>
									</div>
									<div class="form-group mt-20 clearfix search-footer no-radius">
										<div class="col-sm-12 text-center">
											<button type="button" onclick="SaveCommentCode()"
												id="saveReader" class="btn btn-primary">
												<i class="fa fa-floppy-o"></i> บันทึก
											</button>
											<button type="button" id="refresh" class="btn btn-primary">
												<i class="glyphicon glyphicon-refresh"></i> ล้างข้อมูล
											</button>
										</div>
									</div>
								</div>
								<!-- END BOX-BODY -->
							</div>
						</form>
					</div>
					<!-- End detail-area -->
				</div>
				<!-- End detail-area -->
				<div class="form-detail clearfix"
					style="margin-top: -20px; padding-top: 0px;">
					<div class="form-list" id="form-list">
						<form role="form" name="form" action="" method="POST">
							<div class="list-detail-area">
								<table id="requestTypeDataTable"
									class="stripe hover cell-border" cellspacing="0" width="100%"
									align="center">
									<thead>
										<tr
											style="background-color: #399bca; color: white; font-size: 0.9em;">
											<th style="border-right: 1px solid #999" class="text-center">ลำดับ</th>
											<th style="border-right: 1px solid #999" class="text-center">กลุ่ม</th>
											<th style="border-right: 1px solid #999" class="text-center">รหัส</th>
											<th style="border-right: 1px solid #999" class="text-center">รายละเอียด</th>
											<th class="text-center">จัดการ</th>
										</tr>
									</thead>
								</table>
								<input type="hidden" name="oldCodeID" id="oldCodeID" value="" />
								<input type="hidden" name="dataDelete1" id="dataDelete1"
									value="" />
							</div>
						</form>
						<div class="modal fade" id="confirmUpdateModal" tabindex="-1"
							role="dialog" aria-labelledby="confirmModal" aria-hidden="true">
							<div class="modal-dialog" style="width: 400px;">
								<div class="modal-content">
									<div class="modal-header">
										<button type="button" class="close" data-dismiss="modal"
											aria-hidden="true">&times;</button>
										<h4 class="modal-title">บันทึกข้อมูลประเภทคำร้อง</h4>
									</div>
									<div class="modal-body">
										<span class="fa-stack fa-lg mr-10" style=" color:#FC0"> <i class="fa fa-exclamation-triangle fa-stack-2x"></i></span>
										<span id="modal_content_confirmUpdateModal"></span>
									</div>
									<div class="modal-footer">
										<button onclick="updateDataTable()" type="button"
											class="btn btn-primary"><i class="fa fa-floppy-o"></i> บันทึก</button>					
										<button onclick="cancel()" type="button"
											class="btn btn-danger" data-dismiss="modal"><i class="glyphicon glyphicon-floppy-remove"></i> ยกเลิก</button>
									</div>
								</div>
							</div>
						</div>
						<div class="modal fade" id="confirmSaveModal" tabindex="-1"
							role="dialog" aria-labelledby="confirmModal" aria-hidden="true">
							<div class="modal-dialog"  style="width: 400px;">
								<div class="modal-content">
									<div class="modal-header">
										<button type="button" class="close" data-dismiss="modal"
											aria-hidden="true">&times;</button>
										<h4 class="modal-title">บันทึกข้อมูลประเภทคำร้อง</h4>
									</div>
									<div class="modal-body">
										<span class="fa-stack fa-lg mr-10" style=" color:#FC0"> <i class="fa fa-exclamation-triangle fa-stack-2x"></i></span>
										<span id="modal_content_confirmSaveModal"></span>
									</div>
									<div class="modal-footer">
										<button onclick="addDataTable()" type="button"
											class="btn btn-primary"><i class="fa fa-floppy-o"></i> บันทึก</button>
										<button onclick="cancel()" type="button"
											class="btn btn-danger" data-dismiss="modal"><i class="glyphicon glyphicon-floppy-remove"></i> ยกเลิก</button>
									</div>
								</div>
							</div>
						</div>
						<div class="modal fade" id="confirmModal" tabindex="-1"
							role="dialog" aria-labelledby="confirmModal" aria-hidden="true">
							<div class="modal-dialog"  style="width: 400px;">
								<div class="modal-content">
									<div class="modal-header">
										<button type="button" class="close" data-dismiss="modal"
											aria-hidden="true">&times;</button>
										<h4 class="modal-title">ลบข้อมูลประเภทคำร้อง</h4>
									</div>
									<div class="modal-body">
										<span class="fa-stack fa-lg mr-10" style=" color:#FC0"> <i class="fa fa-exclamation-triangle fa-stack-2x"></i></span>
										<span id="modal_content_confirmModal"></span>
									</div>
									<div class="modal-footer">
										<button onclick="confirmdeleteData()" type="submit"
											class="btn btn-primary"><i class="fa fa-floppy-o"></i> ยืนยัน</button>
										<button onclick="cancel()" type="button"
											class="btn btn-danger" data-dismiss="modal"><i class="glyphicon glyphicon-floppy-remove"></i> ยกเลิก</button>
									</div>
								</div>
							</div>
						</div>
						<div class="modal fade" id="warningModal" tabindex="-1"
							role="dialog" aria-labelledby="warningModal" aria-hidden="true">
							<div class="modal-dialog"  style="width: 400px;">
								<div class="modal-content">
									<div class="modal-header">
										<button type="button" class="close" data-dismiss="modal"
											aria-hidden="true">&times;</button>
										<h4 class="modal-title">กรุณากรอกข้อมูลให้ถูกต้อง</h4>
									</div>
									<div class="modal-body">
										<span class="fa-stack fa-lg mr-10" style=" color:#FC0"> <i class="fa fa-exclamation-triangle fa-stack-2x"></i></span>
										<span id="modal_content"></span>
									</div>
									<div class="modal-footer">
										<button type="button" class="btn btn-primary"
											data-dismiss="modal"><i class="glyphicon glyphicon-ok"></i> ตกลง</button>
									</div>
								</div>
							</div>
						</div>

						<div class="modal fade" id="errorModal" tabindex="-1"
							role="dialog" aria-labelledby="errorModal" aria-hidden="true">
							<div class="modal-dialog"  style="width: 400px;">
								<div class="modal-content">
									<div class="modal-header">
										<button type="button" class="close" data-dismiss="modal"
											aria-hidden="true">&times;</button>
										<h4 class="modal-title">ข้อมูลผิดพลาด</h4>
									</div>
									<div class="modal-body">
										<span class="fa-stack fa-lg mr-10" style=" color:#FC0"> <i class="fa fa-exclamation-triangle fa-stack-2x"></i></span>
										<span id="modal_content_errorModal"></span>
									</div>
									<div class="modal-footer" style="text-align: center;">
										<button onclick="location.reload()" type="button"
											class="btn btn-primary" data-dismiss="modal"><i class="glyphicon glyphicon-ok"></i> ตกลง</button>
									</div>
								</div>
							</div>
						</div>

					</div>
				</div>
				<div id="footer-detail">Copyright © สงวนลิขสิทธิ์ พ.ศ.2557 โดย
					การประปานครหลวง</div>
			</div>
		</div>
		<!-- End Detail-area-->

	</div>
	<!-- End Wrapper -->
</body>
</html>